package com.qd.flow.model.config;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 流程节点配置
 *
 * @author sjk
 */
@Getter
@Setter
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@TableName("flow_process_node")
public class FlowProcessNode extends Model<FlowProcessNode> implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 主键
     */
    @TableId(value = "node_id", type = IdType.ASSIGN_ID)
    private String nodeId;
    /**
     * 节点名称
     */
    @TableField("node_name")
    private String nodeName;
    /**
     * 序号
     */
    @TableField("node_number")
    private Integer nodeNumber;
    /**
     * 添加时间
     */
    @TableField("add_time")
    private LocalDateTime addTime;
    /**
     * 更新时间
     */
    @TableField("update_time")
    private LocalDateTime updateTime;
    /**
     * 流程ID
     */
    @TableField("process_id")
    private String processId;
    /**
     * 机构ID
     */
    @TableField("org_id")
    private String orgId;
    /**
     * 操作人
     */
    @TableField("operator")
    private String operator;
    /**
     * 是否启用
     */
    @TableField("enable")
    private String enable;
    /**
     * 审批部门
     */
    @TableField("approval_depart")
    private String approvalDepart;

    public void freeData() {
        this.nodeId = null;
        this.nodeName = null;
        this.nodeNumber = null;
        this.addTime = null;
        this.updateTime = null;
        this.processId = null;
        this.orgId = null;
        this.operator = null;
        this.enable = null;
        this.approvalDepart = null;
    }

}
